<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');

class Slidebar extends CI_Controller {
    function  __construct(){
        parent::__construct();
        $this->load->helper('thoigian');
        $this->load->model('Slidebar_model');         
    }
    function index(){          
        // happening
        $this->load->view(
            'slidebar/happening',array('data'=>$this->Slidebar_model->get_happening())
        );
        
        /// last last credited
        $this->load->view(
            'slidebar/last_credited',array('data'=>$this->Slidebar_model->get_lastcredited())
        );
        //last added
        $this->load->view(
            'slidebar/last_added',array('data'=>$this->Slidebar_model->get_lastadded())
        );
              
        
    }
    function ajax($ro = ''){
        if($ro=='happen'){
            $this->load->view(
            'ajax_happening',array('data'=>$this->Slidebar_model->get_happening())
        );
        }
    }
    
    
}

/* End of file welcome.php */
/* Location: ./application/controllers/welcome.php */